package org.tabcap.main;

import javax.swing.JFrame;

import org.pushingpixels.substance.api.skin.*;
import org.tabcap.TCInstance;

import com.meg.swing_utils.SwingInvoker;
import com.meg.swing_utils.graphics.AWTLoader;
import com.meg.swing_utils.laf.LookAndFeel;

public class TabCapApplication extends SwingInvoker
{
	/**
	 * @param args
	 */
	public static void main(String[] args)
	{
		System.setProperty("sun.java2d.d3d", "false");
		new TabCapApplication().start();
	}

	public void run()
	{
		LookAndFeel.enableDecoration(true);
		LookAndFeel.Substance.init(new OfficeBlack2007Skin());
		
		JFrame frame = new JFrame("TABCAP  -- A Table-Based Computing Application");
		frame.setIconImage(AWTLoader.loadImage("org/tabcap/res/Icon.png"));
		frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
		
		frame.add(new TCInstance(frame));
		
		frame.setSize(900, 600);
		frame.validate();
		frame.setLocationRelativeTo(null);
		frame.setVisible(true);
	}
}